package com.example.designmodule.state;

/**
 * @Author: Dijah
 * @Date: 2023/3/4 11:53
 * @Desc: //关闭状态
 */
public class ClosingState extends LiftState{


    @Override
    public void open() {
        super.context.setLiftState(Context.openningState);
        super.context.open();
    }

    //电梯门关闭，是关闭要实现的动作
    @Override
    public void close() {
        System.out.println("电梯门关闭...");
    }

    @Override
    public void run() {
        super.context.setLiftState(Context.runningState);
        super.context.run();
    }

    @Override
    public void stop() {
        super.context.setLiftState(Context.stoppingState);
        super.context.stop();
    }
}
